-
Notifications
You must be signed in to change notification settings - Fork 15.1k
[CIR] Add support for global ctor/dtor attributes #163247
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
This adds support for adding the `global_ctor` or `global_dtor` attribute to the CIR representation of functions defined with `__attribute__((constructor))` or `__attribute__((destructor))` and adding them to the `@llvm.global_ctors` or `@llvm.global_dtors` list during lowering to LLVM IR.
|
@llvm/pr-subscribers-clangir Author: Andy Kaylor (andykaylor) ChangesThis adds support for adding the Full diff: https://github.com/llvm/llvm-project/pull/163247.diff 11 Files Affected:
|
|
@llvm/pr-subscribers-clang Author: Andy Kaylor (andykaylor) ChangesThis adds support for adding the Full diff: https://github.com/llvm/llvm-project/pull/163247.diff 11 Files Affected:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
This adds support for adding the `global_ctor` or `global_dtor` attribute to the CIR representation of functions defined with `__attribute__((constructor))` or `__attribute__((destructor))` and adding them to the `@llvm.global_ctors` or `@llvm.global_dtors` list during lowering to LLVM IR.
This adds support for adding the
global_ctororglobal_dtorattribute to the CIR representation of functions defined with__attribute__((constructor))or__attribute__((destructor))and adding them to the@llvm.global_ctorsor@llvm.global_dtorslist during lowering to LLVM IR.